﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    public class car:garage
    {
        public string CarName { get; set; }
        public string CarColor { get; set; }
        public int WheelsNum { get; set; }

        public void Behaever()
        {
            if (WheelsNum >= 4)
            {
                Console.WriteLine("车子可以行驶");
            }
            else
            {
                garage.behaver();
                Console.WriteLine("请输入修车厂的名字");
                GarageName = Console.ReadLine();
                Console.WriteLine("请输入修车厂的地址");
                GarageAddres = Console.ReadLine();
                Console.WriteLine("请输入修车厂的电话");
                GaragePhone = int.Parse(Console.ReadLine());
            }
            Console.WriteLine("END");
        }

    }
}
